package cn.wolfcode.edu.service.impl;

import cn.wolfcode.edu.domain.SystemDictionaryItem;
import cn.wolfcode.edu.mapper.SystemDictionaryItemMapper;
import cn.wolfcode.edu.service.ISystemDictionaryItemService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by abb on 2018-07-08.
 */
@Service
public class SystemDictionaryItemServiceImpl implements ISystemDictionaryItemService{
    @Autowired
    private SystemDictionaryItemMapper systemDictionaryItemMapper;
    @Override
    public void deleteByPrimaryKey(Long id) {
        systemDictionaryItemMapper.deleteByPrimaryKey(id);
    }

    @Override
    public void insert(SystemDictionaryItem entity) {
        systemDictionaryItemMapper.insert(entity);
    }

    @Override
    public SystemDictionaryItem selectByPrimaryKey(Long id) {
        return systemDictionaryItemMapper.selectByPrimaryKey(id);
    }

    @Override
    public List<SystemDictionaryItem> selectAll() {
        return systemDictionaryItemMapper.selectAll();
    }

    @Override
    public void updateByPrimaryKey(SystemDictionaryItem entity) {
        systemDictionaryItemMapper.updateByPrimaryKey(entity);
    }
    public List<SystemDictionaryItem> selectItem(Long id){
        return systemDictionaryItemMapper.selectItem(id);
    }




    @Override
    public List<SystemDictionaryItem> listAllItemBySn(String sn) {
         return  systemDictionaryItemMapper.selectAllItemBySn(sn);
    }

}
